type MonitorOptions = {
  flight_data: FlightMission | null;
  local_id?: string;
  url: string;
  platform: Platform;
  mapId?: string;
  isWgsNeeded: boolean;
  airlineOptions: {
    base_airline_options: AirlineOptions;
    upper_airline_options: AirlineOptions;
  };
  markersOptions: {
    landingMarker: MarkerOptions;
    endPointMarker: MarkerOptions;
    planeMarker: MarkerOptions;
  };
  wsMessageFunc?: Function | null;
};
type Platform = 'web' | 'uni-app';

type AirlineOptions = {
  color: string;
  width: number;
  id: string | number;
};
type MarkerOptions = {
  id: string | number;
  width: number;
  height: number;
  anchor: {
    x: number;
    y: number;
  };
};
const monitorConfig: MonitorOptions = {
  flight_data: null,
  local_id: '7f6a474f31f04d51b8940e6dff378fb1',
  url: '',
  platform: 'web',
  mapId: 'map',
  isWgsNeeded: true,
  airlineOptions: {
    base_airline_options: {
      // 底层航线
      color: '#ffe30e',
      width: 2,
      id: '1',
    },
    upper_airline_options: {
      // 上层航线
      color: '#2baaff',
      width: 4,
      id: '2',
    },
  },
  markersOptions: {
    landingMarker: {
      id: 1,
      width: 60,
      height: 130,
      anchor: {
        x: 0.5,
        y: 0.5,
      },
    },
    endPointMarker: {
      id: 2,
      width: 21,
      height: 21,
      anchor: {
        x: 0.5,
        y: 0.5,
      },
    },
    planeMarker: {
      id: 3,
      width: 50,
      height: 50,
      anchor: {
        x: 0.5,
        y: 0.5,
      },
    },
  },
  wsMessageFunc: (userId: string, missionLocalId: string) =>
    '{"uid":"' + userId + '","flight_mission_id":"' + missionLocalId + '"}',
};

export const imgPathConfig = {
  planeImgPathMapBase: '/static/img/feimaToDetail/stat/', // 监控页面飞机图片路径
  planeImgPathCloudBase: '/static/img/feimaToDetail/cloudplay/', // 云播页面飞机图片路径
  signalImageBaseUrl: '/static/img/feimaToDetail/signal_', // 信号图片base地址
  landingPointImgUrl: '/static/img/feimaToDetail/landing_point.png', // 起始点标记图片
  endPointImgUrl: '/static/img/feimaToDetail/end_Point.png', // 结束点标记图片
};
export default monitorConfig;
